home *** CD-ROM | disk | FTP | other *** search
/ HPAVC / HPAVC CD-ROM.iso / MYMUD21.ZIP / MMUD21.ZIP / DOCU / TECHDOCU.DOC < prev    next >
Text File  |  1995-01-21  |  7KB  |  208 lines

  1.               Understand the database and you understand MyMUD.
  2.  
  3.  
  4.  
  5. General remarks:
  6. ================
  7.  
  8. Names:
  9.   Every object can have more than one name. The different names are
  10.   separated by pointcommas.
  11.  
  12. LongText record:
  13.   This record defines a textblock of maximal 2kb with descriptive text.
  14.   This text is stored in the <worldname>.DAT file.
  15.  
  16.  
  17. The ObjRecord definition:
  18. =========================
  19.  
  20. Name:
  21.   This is always the name of the record. For exist and actions the name
  22.   is also the action or exit to type. When an exit is called
  23.  
  24.                            North;Go North;Leave
  25.  
  26.   The user is transported through the exit/action on typing one of those
  27.   names.
  28.  
  29. Password:
  30.   This field is only used for PlayerRecords. (Hmm. why?! It could be usefull
  31.   for exits too..)
  32.  
  33. Key:
  34.  
  35.   The key field can contain a boolean expression. The expression means for
  36.     Players: If a player can be robbed
  37.     Exits:   If a player can pass
  38.     Actions: If a player can call the action
  39.     Things:  If the thing can be taken
  40.  
  41.   If the expression evaluates to true, the action is performed and the
  42.   SUCCESS/OSUCCESS text is shown. If it evaluates false, nothing happens
  43.   and the FAIL/OFAIL text is shown.
  44.  
  45. Location:
  46.   The recordnumber of the location of the object. This can be a room_type
  47.   object or a player_type object.
  48.   For Exit_Type objects it describs the DESTINATION room.
  49.  
  50. Contents:
  51.   For player_type object this starts the chain of items they possess. For
  52.   Room_Type objects this starts the chain of things it contains.
  53.  
  54. Exits:
  55.   For Rooms:    The list of possible exits and actions.
  56.   For Players:  Only one record of the HOME location.
  57.   For Things:   Only one record of the HOME location
  58.  
  59. Owner:
  60.   The owner of the object. Often the creator, but through the ChOwn bit
  61.   or a shop items can change owners. A player has to own an object to
  62.   change it's attributes depending on the player's level.
  63.  
  64.  
  65. Pennies:
  66.   The amound of gold a player has. Coins are found, gained in temples and
  67.   shops or given by a god or wizard. Coins can be stolen (ROB), spend on
  68.   buying things in a shop, or be given away. Creatings objects costs coins.
  69.   For Thing_Type objects the field contains their value for selling or
  70.   sacrificing.
  71.  
  72. ObjType:
  73.   Defines the object type:
  74.       Room_Type   : a location
  75.       Thing_Type  : an object/thing
  76.       Exit_Type   : a exit/action
  77.       Player_Type : a player
  78.       Drone_Type  : an object which follows the player around.
  79.  
  80. ObjLevel:
  81.   Defines a player his level:
  82.      Guest/toad   : The lowestlevel. Not many possibilities
  83.      Player       : Default level, normal play
  84.      Builder      : Can build new objects and locations
  85.      Wizards      : Can also create magic items and change other players
  86.                     their items.
  87.      God          : The owner of the playyard. Can do everything. There is
  88.                     only one god.
  89.  
  90. GenFlags:
  91.   General system flags. At this moment none are defined.
  92.  
  93. Desc:
  94.   A longtext record. Is shown when an object is looked at, read or used with
  95.   not enough parameters.
  96.  
  97. Fail:
  98.   A longtext record. Is shown to the player if a key evaluation fails.
  99.  
  100. Success:
  101.   A LongText record. Is shown to the player if a key evaluation succeeds.
  102.  
  103. OFail:
  104.   A LongText record. Is shown to the other players in the same location when
  105.   a key evaluation fails.
  106.  
  107. Osuccess:
  108.   A LongText record. Is shown to the other players in the same location when
  109.   a key evaluation succeeds.
  110.  
  111. Macro:
  112.   A LongText record. Contains the macro commands which perform the actions
  113.   when an object is used.
  114.  
  115. SEX:
  116.   Nope, not "Yes please" Nerd! The player's sex. Can be Neuter, Female or
  117.   Male.
  118.  
  119. Room_Flags:
  120.   Define the properties of a room_type object.
  121.      Temple_Room: Items dropped here go to their home location. User gets
  122.                   its value in pennies.
  123.      Show_Room:   Items dropped here give their value in pennies to the user.
  124.                   The item gets more expensive.
  125.      Haven_Room:  A quiet place. Users cannot be killed or paged here.
  126.      Loud_Room:   In a room marked as loud, other users can overhear
  127.                   whispers. Sometimes.. scrambled a little..
  128.  
  129. Attr_Flags:
  130.   Defines other attributes of an object:
  131.      Link_Ok_Flag:     Builders and higher can create new exits and actions
  132.                        here.
  133.      Sticky_Flag:      For objects it means that when dropped they go back to
  134.                        their Home location.
  135.                        For players it means that they DON't go home when
  136.                        they leave the mud.
  137.      Teleport_Ok_Flag: It's ok to teleport to this location.
  138.      Invisible_Flag:   Makes the object or player invisible.
  139.      For_Sale_Flag:    Used together with Shop_Type rooms.
  140.      ChOwn_Ok_Flag:    For things this means they can change owners.
  141.                        For players this means they accept the ownership of
  142.                        strange objects.
  143.  
  144. Garbage:
  145.   List of destroyed objects. In a later version on MyMUD should first check
  146.   this list before creating a new object.
  147.  
  148. Finger:
  149.   LongText record. The information in this record is shown whenever a user
  150.   @FINGERs an other user or object with this info set.
  151.  
  152. Storage:
  153.   Ten integers of variable space for use in macro's.
  154.  
  155.  
  156.  
  157. Boolean expressions:
  158. ====================
  159.  
  160. The boolean expression in MyMUD work with objectnumbers. ObjectNumbers
  161. represent players or things. A player can be or cannot be. A player can
  162. have or not have a certain level and an object can be in the possession
  163. of a player or not.
  164.  
  165. Examples:   !1     Means, true if you are not the GOD of the game. (who
  166.                    always has record number 1)
  167.             @W     True if the player has a level Wizard or higher.
  168.             34     True when the player has object #34.
  169.  
  170. These of course are very simple expressions. So there are also operators:
  171.  
  172. & = Logical AND
  173. | = Logical OR
  174. ! = Logical NOT
  175.  
  176. @[P,B,W,G] defines a minimal level. P)layer B)uilder W)izard G)od
  177.  
  178. When in the game ME is translated into the players own recordnumber HERE into
  179. the current location and and items translate into their objectnumbers. I use
  180. names here instead of numbers for clarity. In reality they are translated into
  181. numbers.
  182.  
  183. Now you can make more complex expressions:
  184.  
  185. ME|RED KEY      The owner/player or everybody with the red key
  186. ME|!ME          Always false so lockes an item quite nicely.
  187. @B|GUEST TOKEN  All builders, wizards and the GOD AND the player with the
  188.                 guest token item.
  189.  
  190. Door 1 exit in:  (Red Key)  Exit back: Red Key
  191. next door 2: Exit in (!RED KEY) Exit Back (ME|!ME)
  192.  
  193. The user passes door 1, and can still go back. If he wants to continue though
  194. he has to drop the key (which should be sticky and return to it's home room
  195. for someone else to find) Once door 2 is also passed there is no way back.
  196.  
  197. Expression are also used to lock magic objects. Say you made a potion of
  198. teleport which you want to keep for yourself. Just set the lock to ME
  199. Thisway no other user can use the item.
  200.  
  201. Then there is the $ Symbol which, when used in an expression, is sometimes
  202. true and sometimes false. This to juice up the game with some random
  203. behaviour.
  204.  
  205.  
  206.  
  207.  
  208.